const http = require('http')
const ws = require('ws')
const port = 8001
const socketManager = require('./socketManager')

var httpServer = http.createServer((req, res) => {
  res.end(`welcome to http://localhost:${port}`)
})

socketManager.startSocketService(httpServer)

httpServer.listen(port, () => {
  console.log(`server start at http://localhost:${port}`)
})